<template>
  <div>
    <button @click="add">number 的值是：{{ number }}</button>
  </div>
</template>

<script>
export default {
  data() {
    return {
      number: 0,
    };
  },
  methods: {
    add() {
      this.number++;
    },
  },
  mounted() {
    console.log("number 的值是：" + this.number);
  },
};
</script>

<style scoped></style>
